import 'package:flutter/cupertino.dart';
import 'package:mobile_app.core/core/presentation/helpers/screen_util_mixin.dart';
import 'package:mobile_app.core/core/presentation/widgets/app_button.dart';
import 'package:mobile_app.home.core/core/presentation/localization/translation.dart';
import 'package:mobile_app.home.core/core/presentation/theme/home_core_theme.dart';

class ScaledCardKeyboardTextFieldHintButton extends StatelessWidget with ScreenUtilMixin {
  const ScaledCardKeyboardTextFieldHintButton({
    required this.onPressed,
    super.key,
  });

  final VoidCallback onPressed;

  double get _scaleFactor => logWidthScaleFactor;

  @override
  Widget build(BuildContext context) {
    return AppButton(
      padding: const EdgeInsets.fromLTRB(0, 10, 10, 0) * _scaleFactor,
      onPressed: onPressed,
      child: Container(
        color: HomeCoreTheme.of(context).cardColor,
        child: Padding(
          padding: const EdgeInsets.fromLTRB(10, 5, 10, 5) * _scaleFactor,
          child: Text(
            HomeCoreTranslation.of(context).cardKeyboardTextFieldHintButtonTitle,
            style: HomeCoreTheme.of(context).textTheme.cardKeyboardTextFieldPrimaryButton,
          ),
        ),
      ),
    );
  }
}
